<template>
  <div>
    <HelloWorld />
    <NuxtLink to="/home">home</NuxtLink>
    <br />
    <NuxtLink to="/form-data">form-data</NuxtLink>
    <br />
    <NuxtLink to="/childpage/page-a">page-a</NuxtLink>
    <NuxtLink to="/childpage/page-b">page-b</NuxtLink>
    <h1>{{ data }}</h1>
    <NuxtPage />
  </div>
</template>

<script setup lang="ts">
definePageMeta({
  // layout: false,
  pageTransition: {
    name: "fade",
  },
});

const { data } = await useFetch("/api/test", {
  method: "post",
  body: {
    username: "ZhangSan",
    age: 18,
    gender: "男",
  },
});
console.log(data);
</script>

<style lang="scss" scoped></style>
